package main

import "fmt"

func main()  {
	A := map[string]int{
		"AA":1,
		"BB":2,
	}
	B := map[string]int{"AA":2, "BB":3, "CC":4}
	for k, v := range A{
		_, ok := B[k]
		if ok{
			B[k] += v
		} else{
			B[k] = v
		}

	}
	fmt.Println(B)
}
